import { OrgType, DeployType } from '@/enums/institution';
import { SmsAuditStatusEnum, SmsTypeEnum } from '@/enums/message';
import { TerimalStatusEnum, DispenseStatusEnum, DispenseTypeEnum } from '@/enums/device';
import { IPhoneOrderStateEnum, IsAuthorizationEnum } from '@/enums/phoneAuthEnum';
import {
  LogisticsModeEnum,
  ProductManageMenu,
  ProductType,
  PurchaseLimit,
  ReviewStatus,
} from '@/enums/productManage';
import {
  ApplicationStatusEnum,
  OrganizationTypeEnum,
  ShopStatus,
} from '@/enums/merchantPlatformEnum';
import { ConsumeStatusEnum, OrderPayStatusEnum, OrderStatusEnum, RefundStatusEnum, SettlementStatusEnum, TicketTypeEnum } from '@/enums/orderEnums';
import { PromotionMode, PushShowType, ResourceLeagueMenu } from '@/enums/resourceLeague';
import { FieldValueMenuEnum } from '@/enums/fieldValueEnumManage';
import { ActivityStatusEnum, PublishStatusEnum } from '@/enums/activityEnum';
import { BoStatusEnum, BoTypeEnum, OpReviewStatus } from '@/enums/businessOpportunitiesEnum';

const auditStatus = [
  { dictLabel: '审核成功', dictValue: 0 },
  { dictLabel: '审核被拒绝', dictValue: 1 },
  { dictLabel: '审核中', dictValue: 2 },
  { dictLabel: '已撤回', dictValue: 3 },
  { dictLabel: '审核延后', dictValue: 4 },
];

export default {
  orgType: [
    { dictLabel: '总会', dictValue: OrgType.GENERALCHAMBER },
    { dictLabel: '协会', dictValue: OrgType.ASSOCIATION },
    { dictLabel: '商会', dictValue: OrgType.CHAMBERCOMMERCE },
    { dictLabel: '其他', dictValue: OrgType.OTHER },
  ],
  enabled: [
    { dictLabel: '禁用', dictValue: 0 },
    { dictLabel: '正常', dictValue: 1 },
  ],
  deployType: [
    { dictLabel: 'SAAS部署', dictValue: DeployType.SAAS },
    { dictLabel: '本地部署', dictValue: DeployType.LOCAL },
  ],
  auditStatus: [...auditStatus],
  recordStatus: [
    ...auditStatus,
    {
      dictLabel: '回滚',
      dictValue: 5,
    },
    {
      dictLabel: '已发布',
      dictValue: 6,
    },
  ],
  releaseType: [
    { dictLabel: '正常发布', dictValue: 0 },
    { dictLabel: '回滚发布', dictValue: 1 },
  ],
  dictStatus: [
    { dictLabel: '正常', dictValue: '0' },
    { dictLabel: '禁用', dictValue: '1' },
  ],
  orderState: [
    { dictLabel: '待付款', dictValue: 0 },
    { dictLabel: '已完成', dictValue: 1 },
    { dictLabel: '已关闭', dictValue: 2 },
  ],
  orderType: [
    { dictLabel: '会费', dictValue: 'MEMBER_FEES' },
    { dictLabel: '解锁名片', dictValue: 'UNLOCK_BUSINESS_CARD' },
    { dictLabel: '联系秘书处', dictValue: 'SECRETARIAT' },
    { dictLabel: '解锁供需', dictValue: 'UNLOCK_BUSINESS_OPPORTUNITIES' },
  ],
  payType: [
    { dictLabel: '缴费', dictValue: 'PAY_FEES' },
    { dictLabel: '续费', dictValue: 'RENEW' },
  ],
  rateType: [
    { dictLabel: '单笔百分比', dictValue: 'SINGLE_PERCENT' },
    { dictLabel: '单笔固定值', dictValue: 'SINGLE_FIXED' },
    { dictLabel: '单笔固定值+单笔百分比', dictValue: 'FIXED_MIX_PERCENT' },
    { dictLabel: '单笔百分比+封顶值', dictValue: 'PERCENT_MIX_CAP' },
    { dictLabel: '单笔百分比+保底值', dictValue: 'PERCENT_MIX_GUARANTEED' },
  ],
  merchantStatus: [
    { dictLabel: '未开通', dictValue: 0 },
    { dictLabel: '申请中', dictValue: 1 },
    { dictLabel: '已开通', dictValue: 2 },
  ],
  payMode: [
    { dictLabel: '线上支付', dictValue: 'WECHAT_PAY' },
    { dictLabel: '转账', dictValue: 'TRANSFER_ACCOUNTS' },
  ],
  smsType: [
    { dictLabel: '通知短信', dictValue: SmsTypeEnum.NOTICE },
    { dictLabel: '营销短信', dictValue: SmsTypeEnum.MARKETING },
  ],
  smsAuditStatus: [
    { dictLabel: '待提审', dictValue: SmsAuditStatusEnum.STAY },
    { dictLabel: '已通过', dictValue: SmsAuditStatusEnum.PASSED },
    { dictLabel: '审核中', dictValue: SmsAuditStatusEnum.REVIEW },
    { dictLabel: '已驳回', dictValue: SmsAuditStatusEnum.REJECTED },
  ],
  /** 设备状态 */
  terimalStatus: [
    { dictLabel: '离线', dictValue: TerimalStatusEnum.OFFLINE },
    { dictLabel: '在线', dictValue: TerimalStatusEnum.ONLINE },
    { dictLabel: '无USB插入', dictValue: TerimalStatusEnum.NOTINSERTED },
    { dictLabel: '纸尽', dictValue: TerimalStatusEnum.PAPEROUT },
    { dictLabel: '切刀错误', dictValue: TerimalStatusEnum.KNIFEERROR },
    { dictLabel: '有不可恢复错误', dictValue: TerimalStatusEnum.UNRECOVERABLEERRORS },
    { dictLabel: '打印机离线', dictValue: TerimalStatusEnum.PRINTEROFFLINE },
    { dictLabel: '开盖', dictValue: TerimalStatusEnum.OPENINGCOVER },
    { dictLabel: '高温', dictValue: TerimalStatusEnum.HIGHTEMPERATURE },
  ],
  /** 分配状态 */
  dispenseStatus: [
    { dictLabel: '已分配', dictValue: DispenseStatusEnum.ASSIGNED },
    { dictLabel: '未分配', dictValue: DispenseStatusEnum.UNDISTRIBUTED },
  ],
  /** 分配方式 */
  dispenseType: [
    { dictLabel: '租用', dictValue: DispenseTypeEnum.RENT },
    { dictLabel: '购买', dictValue: DispenseTypeEnum.PURCHASE },
  ],
  /** 小程序授权 */
  isAuthorization: [
    { dictLabel: '已授权', dictValue: IsAuthorizationEnum.AUTHORIZED },
    { dictLabel: '未授权', dictValue: IsAuthorizationEnum.UNAUTHORIZED },
  ],
  phoneOrderState: [
    { dictLabel: '分配中', dictValue: IPhoneOrderStateEnum.ALLOCATING },
    { dictLabel: '分配成功', dictValue: IPhoneOrderStateEnum.ALLOCATED },
    { dictLabel: '分配失败', dictValue: IPhoneOrderStateEnum.ALLOCATERROR },
  ],
  productReviewStatus: [
    { dictLabel: '全部', dictValue: '' },
    { dictLabel: '待审核', dictValue: ReviewStatus.Pending },
    { dictLabel: '审核通过', dictValue: ReviewStatus.Approved },
    { dictLabel: '审核不通过', dictValue: ReviewStatus.Rejected },
  ],
  productManageMenu: [
    { dictLabel: '产品库', dictValue: ProductManageMenu.ProductManage },
    { dictLabel: '产品审核', dictValue: ProductManageMenu.ProductReview },
  ],
  productType: [
    { dictLabel: '实物商品', dictValue: ProductType.Physical },
    { dictLabel: '卡券商品', dictValue: ProductType.CouponVerification },
    { dictLabel: '虚拟商品', dictValue: ProductType.Virtual },
  ],
  logisticsMode: [
    { dictLabel: '快递发货（全国包邮）', dictValue: LogisticsModeEnum.EXPRESS },
    { dictLabel: '无需物流', dictValue: LogisticsModeEnum.NO_EXPRESS },
    { dictLabel: '到店核销', dictValue: LogisticsModeEnum.TO_STORE },
  ],
  purchaseLimit: [
    { dictLabel: '限制', dictValue: PurchaseLimit.YES },
    { dictLabel: '不限制', dictValue: PurchaseLimit.NO },
  ],
  shopStatus: [
    { dictLabel: '启用', dictValue: ShopStatus.YES },
    { dictLabel: '禁用', dictValue: ShopStatus.NO },
  ],
  isBindingAppMall: [
    { dictLabel: '已绑定', dictValue: ShopStatus.YES },
    { dictLabel: '未绑定', dictValue: ShopStatus.NO },
  ],
  orderPayStatus: [
    // { dictLabel: '未支付', dictValue: OrderPayStatusEnum.NO },
    // { dictLabel: '支付中', dictValue: OrderPayStatusEnum.DURING },
    { dictLabel: '已支付', dictValue: OrderPayStatusEnum.SUCCESS },
    // { dictLabel: '支付失败', dictValue: OrderPayStatusEnum.FAIL },
    // { dictLabel: '支付关闭', dictValue: OrderPayStatusEnum.CLOSE },
    { dictLabel: '已退款', dictValue: OrderPayStatusEnum.Refund },
  ],
  orderStatus: [
    { dictLabel: '待支付', dictValue: OrderStatusEnum.WAIT_PAY, dictType: 'processing' },
    { dictLabel: '已支付', dictValue: OrderStatusEnum.PAYMENT, dictType: 'success' },
    { dictLabel: '待发货', dictValue: OrderStatusEnum.WAIT_DELIVER, dictType: 'default' },
    { dictLabel: '待收货/已发货', dictValue: OrderStatusEnum.WAIT_RECEIVE, dictType: 'default' },
    { dictLabel: '已签收', dictValue: OrderStatusEnum.SIGN_RECEIPT, dictType: 'success' },
    { dictLabel: '待使用', dictValue: OrderStatusEnum.WAIT_USE, dictType: 'processing' },
    { dictLabel: '退换/售后', dictValue: OrderStatusEnum.AFTERSALES, dictType: 'warning' },
    { dictLabel: '部分售后', dictValue: OrderStatusEnum.PART_AFTERSALES, dictType: 'warning' },
    { dictLabel: '已完成', dictValue: OrderStatusEnum.DONE, dictType: 'success' },
    { dictLabel: '已取消', dictValue: OrderStatusEnum.CANCELED, dictType: 'error' },
  ],
  settlementStatus: [
    { dictLabel: '待结算', dictValue: SettlementStatusEnum.NO, dictType: 'processing' },
    { dictLabel: '已结算', dictValue: SettlementStatusEnum.YES, dictType: 'success' },
    { dictLabel: '已退款', dictValue: SettlementStatusEnum.Refund, dictType: 'error' },
  ],
  organizationTypes: [
    { dictLabel: '个人账户', dictValue: OrganizationTypeEnum.SmallMicroMerchant },
    { dictLabel: '企业账户', dictValue: OrganizationTypeEnum.Enterprise },
    { dictLabel: '个体工商户', dictValue: OrganizationTypeEnum.IndividualBusiness },
    { dictLabel: '社会组织账户', dictValue: OrganizationTypeEnum.SocialOrganization },
  ],
  applicationStatus: [
    { dictLabel: '资料校验中', dictValue: ApplicationStatusEnum.Checking },
    { dictLabel: '待账户验证', dictValue: ApplicationStatusEnum.AccountNeedVerify },
    { dictLabel: '审核中', dictValue: ApplicationStatusEnum.Auditing },
    { dictLabel: '审核拒绝', dictValue: ApplicationStatusEnum.REJECTED },
    { dictLabel: '已冻结', dictValue: ApplicationStatusEnum.FROZEN },
    { dictLabel: '已作废', dictValue: ApplicationStatusEnum.CANCELED },
    { dictLabel: '审核失败', dictValue: ApplicationStatusEnum.AuditFail },
    { dictLabel: '待签约', dictValue: ApplicationStatusEnum.NeedSign },
    { dictLabel: '完成', dictValue: ApplicationStatusEnum.Finish },
  ],
  resourceLeagueMenu: [
    { dictLabel: '联盟产品库', dictValue: ResourceLeagueMenu.PRODUCTLIBRARY },
    { dictLabel: '产品审核', dictValue: ResourceLeagueMenu.PRODUCTAUDIT },
    { dictLabel: '精选板块管理', dictValue: ResourceLeagueMenu.SELECTEDPLATE },
    { dictLabel: '联盟组织管理', dictValue: ResourceLeagueMenu.LEAGUEORGANIZATION },
    { dictLabel: '订单统计', dictValue: ResourceLeagueMenu.ORDERSSTATISTICS },
    // { dictLabel: '数据统计', dictValue: ResourceLeagueMenu.DATASTATISTICS },
    { dictLabel: '联盟配置', dictValue: ResourceLeagueMenu.LEAGUECONFIG },
  ],
  pushShowType: [
    { dictLabel: '全部组织可见', dictValue: PushShowType.ALLSHOW },
    { dictLabel: '部分组织可见', dictValue: PushShowType.PARTSHOW },
    { dictLabel: '全部不可见', dictValue: PushShowType.ALLHIDE },
  ],
  promotionMode: [
    { dictLabel: '全部组织首页', dictValue: PromotionMode.ALLSHOW },
    { dictLabel: '部分组织首页', dictValue: PromotionMode.PARTSHOW },
    { dictLabel: '不展示', dictValue: PromotionMode.ALLHIDE },
  ],
  fieldValueMenuEnum: [
    { dictLabel: '国家', dictValue: FieldValueMenuEnum.Country },
    { dictLabel: '毕业学校', dictValue: FieldValueMenuEnum.GraduationSchool },
    { dictLabel: '毕业院系', dictValue: FieldValueMenuEnum.GraduatingInstitution },
    { dictLabel: '专业', dictValue: FieldValueMenuEnum.GraduationMajor },
    { dictLabel: '单位类别', dictValue: FieldValueMenuEnum.CompanyCategory },
    { dictLabel: '所属行业', dictValue: FieldValueMenuEnum.IndustrySector },
    { dictLabel: '会员职务', dictValue: FieldValueMenuEnum.MembershipTitle },
    { dictLabel: '活动类型', dictValue: FieldValueMenuEnum.ActivityType },
    { dictLabel: '供需合作类型', dictValue: FieldValueMenuEnum.CooperationTypes },
  ],
  ticketType: [
    { dictLabel: '免费票', dictValue: TicketTypeEnum.free },
    { dictLabel: '付费票', dictValue: TicketTypeEnum.pay },
  ],
  refundStatus: [
    { dictLabel: '待审核', dictValue: RefundStatusEnum.UNREFUNDED },
    { dictLabel: '已退款', dictValue: RefundStatusEnum.REFUNDED },
    { dictLabel: '退款中', dictValue: RefundStatusEnum.REFUNDING },
    { dictLabel: '部分退款', dictValue: RefundStatusEnum.PART_REFUND },
    { dictLabel: '退款失败', dictValue: RefundStatusEnum.REFUND_FAILED },
  ],
  consumeStatus: [
    { dictLabel: '已核销', dictValue: ConsumeStatusEnum.YES },
    { dictLabel: '未核销', dictValue: ConsumeStatusEnum.NO },
  ],
  activityStatus: [
    { dictLabel: '活动发布', dictValue: ActivityStatusEnum.ISSUE, dictType: 'success' },
    { dictLabel: '报名进行中', dictValue: ActivityStatusEnum.REGISTERSTART, dictType: 'processing' },
    { dictLabel: '报名结束', dictValue: ActivityStatusEnum.REGISTEREND, dictType: 'default' },
    { dictLabel: '活动进行中', dictValue: ActivityStatusEnum.START, dictType: 'success' },
    { dictLabel: '活动结束', dictValue: ActivityStatusEnum.END, dictType: 'default' },
    { dictLabel: '活动取消', dictValue: ActivityStatusEnum.CANCEL, dictType: 'error' },
    // { dictLabel: '活动审核中', dictValue: ActivityStatusEnum.INREVIEW, dictType: 'warning' },
    // { dictLabel: '活动审核失败', dictValue: ActivityStatusEnum.REVIEWERR, dictType: 'success' },
    // { dictLabel: '未发布', dictValue: ActivityStatusEnum.REVIEWERR, dictType: 'default' },
  ],
  publishStatus: [
    { dictLabel: '未发布', dictValue: PublishStatusEnum.UNISSUE, dictType: 'default' },
    { dictLabel: '已发布', dictValue: PublishStatusEnum.ISSUE, dictType: 'processing' },
    { dictLabel: '已下架', dictValue: PublishStatusEnum.SOLDOUT, dictType: 'error' },
  ],
  reviewStatus: [
    { dictLabel: '待审核', dictValue: OpReviewStatus.Pending, dictType: 'processing' },
    { dictLabel: '已通过', dictValue: OpReviewStatus.Approved, dictType: 'blue' },
    { dictLabel: '已驳回', dictValue: OpReviewStatus.Rejected, dictType: 'error' },
    { dictLabel: '已失效', dictValue: OpReviewStatus.Expired, dictType: 'default' },
  ],
  boStatus: [
    { dictLabel: '草稿', dictValue: BoStatusEnum.Draft, dictType: 'default' },
    { dictLabel: '生效中', dictValue: BoStatusEnum.Active, dictType: 'blue' },
    { dictLabel: '已过期', dictValue: BoStatusEnum.Expired, dictType: 'default' },
    { dictLabel: '已关闭', dictValue: BoStatusEnum.Closed, dictType: 'default' },
    { dictLabel: '审核中', dictValue: BoStatusEnum.Reviewing, dictType: 'processing' },
    { dictLabel: '审核失败', dictValue: BoStatusEnum.ReviewFailed, dictType: 'error' },
  ],
  boType: [
    { dictLabel: '供应', dictValue: BoTypeEnum.Supply, dictType: 'orange' },
    { dictLabel: '需求', dictValue: BoTypeEnum.Demand, dictType: 'red' },
  ]
};
